package org.cqut.system.course.domain;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;

import java.math.BigDecimal;
import java.util.Date;

import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import org.cqut.framework.web.domain.BaseEntity;

/**
 * @author XiAoXu
 * @TableName cw_course
 */
@TableName(value = "cw_course")
@Data
@Accessors(chain = true)
@EqualsAndHashCode(callSuper = true)
public class Course extends BaseEntity {
    /**
     * 课程Id
     */
    @TableId(value = "course_id", type = IdType.AUTO)
    private Long courseId;

    /**
     * 课程名
     */
    @TableField(value = "course_name")
    private String courseName;

    /**
     * 课程学时
     */
    @TableField(value = "course_period")
    private Short coursePeriod;

    /**
     * 课程学分
     */
    @TableField(value = "course_point")
    private BigDecimal coursePoint;

    /**
     * 课程状态
     */
    @TableField(value = "course_status")
    private Byte courseStatus;

    /**
     * 课程结束时间
     */
    @TableField(value = "course_end_time")
    @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
    private Date courseEndTime;

    /**
     * 课程简介
     */
    @TableField(value = "course_content")
    private String courseContent;

    /**
     * 课程封面
     */
    @TableField(value = "course_profile")
    private String courseProfile;
}